From: Ævar Arnfjörð Bjarmason Date: Sun, 8 Jan 2006 10:37:25 +0000 (+0000) Subject: * Adding a noxml option for skipping XML well formdness tests in parser tests, X-Git-Tag: 1.6.0~695 X-Git-Url: http://git.cyclocoop.org/%28%5B%5E/404?a=commitdiff_plain;h=006ea63555b5e63d0f20a88e131daa33986f5fb2;p=lhc%2Fweb%2Fwiklou.git * Adding a noxml option for skipping XML well formdness tests in parser tests, used in the extension tag tests which don't return xhtml --- diff --git a/maintenance/parserTests.inc b/maintenance/parserTests.inc index c58c8aa6fc..2abe8ae1ba 100644 --- a/maintenance/parserTests.inc +++ b/maintenance/parserTests.inc @@ -237,6 +237,8 @@ class ParserTest { $titleText = 'Parser test'; } + $noxml = (bool)preg_match( '~\\b noxml \\b~x', $opts ); + $parser =& new Parser(); wfRunHooks( 'ParserTestParser', array( &$parser ) ); $title =& Title::makeTitle( NS_MAIN, $titleText ); @@ -260,7 +262,7 @@ class ParserTest { $this->teardownGlobals(); - if( $result === $out && $this->wellFormed( $out ) ) { + if( $result === $out && ( $noxml === true || $this->wellFormed( $out ) ) ) { return $this->showSuccess( $desc ); } else { return $this->showFailure( $desc, $result, $out );